home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 5 / Apprentice-Release5.iso / Information / CSMP Digest / volume 1 / csmp-v1-170.txt < prev    next >
Encoding:
Text File  |  1992-12-31  |  39.1 KB  |  1,051 lines  |  [TEXT/R*ch]

  1. C.S.M.P. Digest             Tue, 18 Aug 92       Volume 1 : Issue 170
  2.  
  3. Today's Topics:
  4.  
  5.     Sockets interface to MacTCP
  6.     Beginner want to know about _Jackson
  7.     Selecting graphics
  8.     Building Installation Disks
  9.     Gettting the size of a window or Graf Port
  10.     How to play MIDI resources?
  11.     What is LDIVT (referenced in an MPW .o/.lib file?)
  12.     texedit records >32K (SUMMARY)
  13.     Has anybody got disk dragging to work?
  14.     ioCompletion and AppleTalk
  15.     Catching phys ATalk connection
  16.  
  17.  
  18.  
  19. The Comp.Sys.Mac.Programmer Digest is moderated by Michael A. Kelly.
  20.  
  21. The digest is a collection of article threads from the internet newsgroup
  22. comp.sys.mac.programmer.  It is designed for people who read c.s.m.p. semi-
  23. regularly and want an archive of the discussions.  If you don't know what a
  24. newsgroup is, you probably don't have access to it.  Ask your systems
  25. administrator(s) for details.  (This means you can't post questions to the
  26. digest.)
  27.  
  28. Each issue of the digest contains one or more sets of articles (called
  29. threads), with each set corresponding to a 'discussion' of a particular
  30. subject.  The articles are not edited; all articles included in this digest
  31. are in their original posted form (as received by our news server at
  32. cs.uoregon.edu).  Article threads are not added to the digest until the last
  33. article added to the thread is at least one month old (this is to ensure that
  34. the thread is dead before adding it to the digest).  Article threads that
  35. consist of only one message are generally not included in the digest.
  36.  
  37. The entire digest is available for anonymous ftp from ftp.cs.uoregon.edu
  38. [128.223.8.8] in the directory /pub/mac/csmp-digest.  Be sure to read the
  39. file /pub/mac/csmp-digest/README before downloading any files.  The most
  40. recent issues are available from sumex-aim.stanford.edu [36.44.0.6] in the
  41. directory /info-mac/digest/csmp.  If you don't have ftp capability, the sumex
  42. archive has a mail server; send a message with the text '$MACarch help' (no
  43. quotes) to LISTSERV@ricevm1.rice.edu for more information.
  44.  
  45. The digest is also available via email.  Just send a note saying that you
  46. want to be on the digest mailing list to mkelly@cs.uoregon.edu, and you will
  47. automatically receive each new issue as it is created.  Sorry, back issues
  48. are not available through the mailing list.
  49.  
  50. Send administrative mail to mkelly@cs.uoregon.edu.
  51.  
  52.  
  53. -------------------------------------------------------
  54.  
  55. From: MikeSummers@cup.portal.com (Michael - Summers)
  56. Subject: Sockets interface to MacTCP
  57. Date: 14 Jul 92 16:30:51 GMT
  58. Organization: The Portal System (TM)
  59.  
  60. Does anyone in NetLand have a pointer to a UNIX sockets interface that
  61. will work with MacTCP?
  62.  
  63. Much thanks in advance, Mike.
  64.  
  65. +++++++++++++++++++++++++++
  66.  
  67. From: jbrowne@void.ncsa.uiuc.edu (Jim Browne)
  68. Organization: University of Illinois at Urbana
  69. Date: Tue, 14 Jul 1992 22:39:04 GMT
  70.  
  71. MikeSummers@cup.portal.com (Michael - Summers) writes:
  72.  
  73. >Does anyone in NetLand have a pointer to a UNIX sockets interface that
  74. >will work with MacTCP?
  75.  
  76. >Much thanks in advance, Mike.
  77.  
  78. You can try Charlie's socket library in misc/unsupported on ftp.ncsa.uiuc.edu
  79.  
  80.  
  81. - -- 
  82. Jim Browne                                          | jbrowne@ncsa.uiuc.edu  |
  83. NCSA/STG System Administrator                       | stgadmin@ncsa.uiuc.edu |
  84. System Administration: Where the fun never ends...  | (217) 244-7798         |
  85. I've nuked the .sig 'cause Usenet Looooooooooosers are retentive about spelling.
  86.  
  87. +++++++++++++++++++++++++++
  88.  
  89. From: ejohnson@sparc3.cs.uiuc.edu (Eric E Johnson)
  90. Organization: University of Illinois at Urbana-Champaign
  91. Date: Wed, 15 Jul 1992 00:02:53 GMT
  92.  
  93. >MikeSummers@cup.portal.com (Michael - Summers) writes:
  94.  
  95. >>Does anyone in NetLand have a pointer to a UNIX sockets interface that
  96. >>will work with MacTCP?
  97.  
  98. >>Much thanks in advance, Mike.
  99.  
  100. If you are not a fan of sockets, you can always try the Think C MacTCP
  101. classes.  You'll find them at ftp.brown.edu in /pub/tcl/...
  102.  
  103. - -- 
  104. Eric E Johnson             | "For a successful technology, reality must
  105. ejohnson@a.cs.uiuc.edu     |  take precedence over public relations, for
  106. eej37047@uxa.cso.uiuc.edu  |  Nature cannot be fooled." - Richard Feynman
  107.  
  108. +++++++++++++++++++++++++++
  109.  
  110. From: davidp@calvin.usc.edu (David Peterson)
  111. Date: 15 Jul 1992 12:58:49 -0700
  112. Organization: University of Southern California, Los Angeles, CA
  113.  
  114.  
  115. In article <1992Jul15.000253.12010@sunb10.cs.uiuc.edu>, ejohnson@sparc3.cs.uiuc.edu (Eric E Johnson) writes:
  116. |> >MikeSummers@cup.portal.com (Michael - Summers) writes:
  117. |> 
  118. |> >>Does anyone in NetLand have a pointer to a UNIX sockets interface that
  119. |> >>will work with MacTCP?
  120. |> 
  121. |> >>Much thanks in advance, Mike.
  122. |> 
  123. |> If you are not a fan of sockets, you can always try the Think C MacTCP
  124. |> classes.  You'll find them at ftp.brown.edu in /pub/tcl/...
  125. |> 
  126.  
  127. I've got a C++ class that wraps around the MacTCP calls pretty well. Its
  128. got some higher level routines that mimic BSD sockets (sort of). All the
  129. receiving is done "at interupt" so you don't have to mess with timeouts
  130. and retries.
  131.  
  132. If anyone is interested drop me a line.
  133.  
  134. - -dave.
  135.  
  136. Note: You won't be able to use my code to compile BSD source, the semantics
  137. are similar, but not the same. Even though, its easier than the suite of
  138. PBControl calls.
  139.  
  140. ---------------------------
  141.  
  142. From: abduls@aix.rpi.edu (Saiful Azuan Abdul Aziz)
  143. Subject: Beginner want to know about _Jackson
  144. Organization: Rensselaer Polytechnic Institute, Troy, NY
  145. Date: Wed, 15 Jul 1992 09:43:45 GMT
  146.  
  147. Hi all Mac gurus,
  148.     Recently, while doing some programming, I got a bus error. MacsBug told me that it happened while my program tried to fetch some instructions in _Jackson. System Error #25 also occurred while my program tried to call _Jackson. 
  149.  
  150. Question : What is the trap called _Jackson. What _Jackson did exactly. Is there any documentation about this trap? I tried to look up in IM but no luck at all. Can somebody tell me.
  151.  
  152. Extra credit : Who is _Jackson? Somebody in apple may be?
  153.  
  154. Thanks in advance.
  155.  
  156. Saiful
  157. **********
  158. internet: abduls@rpi.edu bitnet:saiful@rpitsmts aol:azrin compu$erve:70760,371
  159.  
  160.  
  161. +++++++++++++++++++++++++++
  162.  
  163. From: Bruce.Hoult@bbs.actrix.gen.nz
  164. Date: Wed, 15 Jul 1992 15:06:45 GMT
  165. Organization: Actrix Information Exchange
  166.  
  167. In article <50jx#+r@rpi.edu> abduls@aix.rpi.edu (Saiful Azuan Abdul Aziz) writes:
  168.  
  169. > Extra credit : Who is _Jackson? Somebody in apple may be?
  170.  
  171. _Jackson is "Jackson Pollock", a famous abstract expressionist drip painter --
  172. check your copy of the after dark module "Modern Art" for more details :-)
  173.  
  174. It was also the internal name for 32-bit Quickdraw.
  175.  
  176. The chances are that your crash has nothing to do with the _Jackson routine,
  177. it's just that Macsbug couldn't find any better name for that part of the
  178. ROMs -- you'll probably find that the offset was something humungous, e.g.
  179. _Jackson + XXXX.  _Jackson seems to have taken the place of _StripAddress
  180. as the bogus crash point of choice...
  181.  
  182. - -- Bruce
  183. - -- 
  184. Bruce.Hoult@bbs.actrix.gen.nz   Twisted pair: +64 4 477 2116
  185. BIX: brucehoult                 Last Resort:  PO Box 4145 Wellington, NZ
  186. "Cray's producing a 200 MIPS personal computer with 64MB RAM and a 1 GB
  187. hard disk that fits in your pocket!"   "Great!  Is it PC compatable?"
  188.  
  189. +++++++++++++++++++++++++++
  190.  
  191. From: lari@jackson.cs.unc.edu (Humayun Lari)
  192. Date: 15 Jul 92 19:34:38 GMT
  193. Organization: University of North Carolina, Chapel Hill
  194.  
  195. In article <1992Jul15.150645.593@actrix.gen.nz> Bruce.Hoult@bbs.actrix.gen.nz writes:
  196. >The chances are that your crash has nothing to do with the _Jackson routine,
  197. >it's just that Macsbug couldn't find any better name for that part of the
  198. >ROMs -- you'll probably find that the offset was something humungous, e.g.
  199. >_Jackson + XXXX.
  200.  
  201. Since the original poster said that Macsbug reported a system error of 25,
  202. it could well be that QuickDraw simply ran out of memory. If so, the
  203. PC should point to a _Debugger instruction (I think the location is _Jackson
  204. + $0000). Of course, this should only happen if the programmer's done something
  205. insanely strange. :-) (This is documented in the Q&A Stack, BTW).
  206.  
  207. >  _Jackson seems to have taken the place of _StripAddress
  208. >as the bogus crash point of choice...
  209.  
  210. Yeah, why *does* that always happen?!?! :-)
  211.  
  212.  
  213. Humayun Lari
  214. (lari@cs.unc.edu)
  215. ObSig: "Technology changes rapidly; people and meaning do not." -- Kevin Bjorke
  216.  
  217. +++++++++++++++++++++++++++
  218.  
  219. From: sll2@cunixa.cc.columbia.edu (Steven L Levitt)
  220. Organization: Columbia University
  221. Date: Wed, 15 Jul 1992 19:09:23 GMT
  222.  
  223. In article <50jx#+r@rpi.edu> abduls@aix.rpi.edu (Saiful Azuan Abdul Aziz) writes:
  224. >Hi all Mac gurus,
  225. >    Recently, while doing some programming, I got a bus error. MacsBug told me that it happened while my program tried to fetch some instructions in _Jackson. System Error #25 also occurred while my program tried to call _Jackson. 
  226. >
  227. >Question : What is the trap called _Jackson. What _Jackson did exactly. Is there any documentation about this trap? I tried to look up in IM but no luck at all. Can somebody tell me.
  228. >
  229. >Extra credit : Who is _Jackson? Somebody in apple may be?
  230. >
  231. >Thanks in advance.
  232. >
  233. >Saiful
  234. >**********
  235. >internet: abduls@rpi.edu bitnet:saiful@rpitsmts aol:azrin compu$erve:70760,371
  236. >
  237.  
  238.  
  239. I believe _Jackson may be a QuickDraw related trap.  In a book I recently
  240. bought, _Programming QuickDraw_, the authors, David A. Surovell, Frederick M. 
  241. Hall and Konstantin Othmer, make passing reference to the fact that when color
  242. QuickDraw was being developed, it was nicknamed Jackson Pollack (asp?, after
  243. the artist.  I don't believe the book ever mentions any kind of trap, however.
  244. - ----------------
  245. Steven L. Levitt  sll2@cunixa.cc.columbia.edu
  246. An Undergrad
  247.  
  248.  
  249. ---------------------------
  250.  
  251. From: erh0362@tesla.njit.edu (Elliotte Rusty Harold)
  252. Subject: Selecting graphics
  253. Date: 15 Jul 92 12:38:37 GMT
  254. Organization: New Jersey Institute of Technology
  255.  
  256.  
  257.     Can anyone help me with some advice or sample source code on selections 
  258. in a graphics program?  All my references deal strictly with selecting things 
  259. as text.  I want to be able to click and drag over a rectangular grid of 
  260. squares and store the resulting rectangle as a PICT and as a private kind of 
  261. scrap on the clipboard.  I'd like to draw a dotted-line-bordered rectangle as I 
  262. drag as seems to be the standard in draw and paint applications.  Does anyone 
  263. have any hints for doing this?
  264.  
  265. Elliotte Rusty Harold        Department of Applied Mathematics
  266. elharo@m.njit.edu        New Jersey Institute of Technology
  267. erh0362@tesla.njit.edu        Newark, NJ 07103
  268.  
  269. +++++++++++++++++++++++++++
  270.  
  271. From: oster@well.sf.ca.us (David Phillip Oster)
  272. Organization: Whole Earth 'Lectronic Link
  273. Date: Thu, 16 Jul 1992 05:58:57 GMT
  274.  
  275. In article <1992Jul15.073837.1@tesla.njit.edu> erh0362@tesla.njit.edu (Elliotte Rusty Harold) writes:
  276. >    Can anyone help me with some advice or sample source code on selections 
  277. >in a graphics program? 
  278. The basic idea is as follows (forgive me, this is off the top of my head)
  279. Point where, anchor, oldWhere;
  280. Rect    marqueeR;
  281.  
  282. GetMouse(&where);
  283. oldWhere = anchor = where;
  284. PenPat(gray);
  285. PenMode(patXor);
  286. while(StillDown()){
  287.     GetMouse(&where);
  288.     if( ! EqualPt(where, oldWhere)){
  289.         FrameRect(&marqueeR);
  290.         Pt2Rect(where, anchor, &marqueeR);
  291.         FrameRect(&marqueeR);
  292.         oldWhere = where;
  293.     }
  294. }
  295. PenNormal();
  296.  
  297. In order to get the "moving ants" animation, things are a little trickier.
  298. Instead of the n ormal 0101010 gray, you use 011011011 as the gray.
  299. Each time through the loop, you check TickCount(). If TickCount() has changed,
  300. you compute a new pattern such that when you Xor the new pattern with 
  301. 0110110 you get
  302. 1011011 and FrameRect the marqueeR with this combined pattern. You then
  303. remember that the pattern of the marqueeR is now 1011011, so you can handle
  304. updtae events. You put the same code in your idle event handler. The whole
  305. works takes a couple of 100 lines of code to do it right.
  306.  
  307. ---------------------------
  308.  
  309. From: wa366@sdcc12.ucsd.edu (Scott Kelley)
  310. Subject: Building Installation Disks
  311. Date: 15 Jul 92 15:21:18 GMT
  312.  
  313. Can anyone offer me any suggestions on how I should set up our
  314. installation procedure for our software?
  315.  
  316. We're writing a large multimedia program using MacroMind Director.
  317. Currently the files take 7.5mb of disk space, but this will
  318. eventually get a LOT bigger (i.e. someday we may have to break down
  319. and go to CD's) since the project is still in it's early stages.
  320.  
  321. We'd like to have as simple a setup as possible, since most of the
  322. people we send disks out to (they're only demo copies now, showing
  323. what we've already done) aren't all that computer-literate. Our
  324. current setup requires the user to run two self-extracting archives,
  325. and then copy some additional files into specific folders with
  326. specific names. Very messy.
  327.  
  328. What I'm wondering is, can any of the commercial archivers (Stuffit,
  329. Compact Pro) build an automated self-extracting archive that spans
  330. multiple volumes? I've played with some of them, and all I can seem
  331. to get is an archive that the user has to combine manually. But we
  332. need the process to be automatic. (I should also add that so far we
  333. haven't generated a file that won't fit onto an HD disk after it's
  334. been compressed, but that will eventually change too...)
  335.  
  336. The other alternative I'm thinking of is licensing Apple's
  337. installer, along with a compression engine for the installer (like
  338. the one used in the Word 5 install). We don't need all of the fancy
  339. options that Apple's installer offers YET, but that too may change.
  340.  
  341. Regardless of what we do, some kind of compression is required. We
  342. get about 50-60% compression of our files no matter what archiver we
  343. use.
  344.  
  345. Can anyone give me any suggestions or recommendations?
  346.  
  347. Thanks,
  348.  
  349. Scott
  350.  
  351. - -------------------------------------------------
  352. Scott Kelley, sakelley@ucsd.edu, (619) 534-8560
  353. Multimedia Interactive Learning Laboratory (MILL)
  354. Department of Biology, UC San Diego
  355. - -------------------------------------------------
  356.  
  357.  
  358. +++++++++++++++++++++++++++
  359.  
  360. From: anders@verity.com (Anders Wallgren)
  361. Date: 15 Jul 92 16:41:01 GMT
  362. Organization: Verity, Inc., Mountain View, CA, USA
  363.  
  364. In article <35700@sdcc12.ucsd.edu> Scott Kelley,
  365. wa366@sdcc12.ucsd.edu writes:
  366. >What I'm wondering is, can any of the commercial archivers
  367. (Stuffit,
  368. >Compact Pro) build an automated self-extracting archive that spans
  369. >multiple volumes?
  370.  
  371. Stuffit has action atoms for Apple's Installer that allows you to
  372. do this.
  373.  
  374. ---------------------------
  375.  
  376. From: Jerome Chan <yjc@po.cwru.edu>
  377. Subject: Gettting the size of a window or Graf Port
  378. Organization: Alethea, The Twilight World!
  379. Date: Thu, 16 Jul 92 03:02:58 GMT
  380.  
  381.   How does one get the dimensions of a window? I'm trying to centre a
  382. window before bringing it up. System 7 has the auto positioning (check
  383. out the ResEdit 2.11) but I am writing for some system 6.x machines as
  384. well. 
  385.  
  386.   Do I use portRect? Someone mentioned that I should use visRgn instead.
  387. Is there a FAQ somewhere that I could look through?
  388.  
  389. - ---
  390.  Fading
  391.  
  392. "No Lah! Sure or not one? Dunno leh! Nebber Mind! Like that one!
  393. Terriblur Lah!"
  394.  
  395. +++++++++++++++++++++++++++
  396.  
  397. From: oster@well.sf.ca.us (David Phillip Oster)
  398. Organization: Whole Earth 'Lectronic Link
  399. Date: Thu, 16 Jul 1992 06:20:01 GMT
  400.  
  401. In article <1992Jul16.030258.11334@usenet.ins.cwru.edu> Jerome Chan <yjc@po.cwru.edu> writes:
  402. _>  How does one get the dimensions of a window? I'm trying to centre a
  403. _>window before bringing it up.
  404.  
  405. _>  Do I use portRect? Someone mentioned that I should use visRgn instead.
  406. _>Is there a FAQ somewhere that I could look through?
  407.  
  408. thePort->portRect gives you the size of the window's content area. If the window
  409. almost fills the screen, this can put the titlebar under the menubar.  Better
  410. you should use (**thePort->visRgn).rgnBBox (good idea to copy it into a 
  411. temporary rect, in case the stuff you are using moves memory, since the visRgn
  412. is a handle.)  The visRgn is in window local coordinates, so for a normal,
  413. 20 pixel high title bar, the top will be at -20.
  414.  
  415. +++++++++++++++++++++++++++
  416.  
  417. From: jcav@quads.uchicago.edu (JohnC)
  418. Organization: The Royal Society for Putting Things on Top of Other Things
  419. Date: Thu, 16 Jul 1992 16:44:05 GMT
  420.  
  421. In article <BrGxLE.LIF@well.sf.ca.us> oster@well.sf.ca.us (David Phillip Oster) writes:
  422. >In article <1992Jul16.030258.11334@usenet.ins.cwru.edu> Jerome Chan <yjc@po.cwru.edu> writes:
  423. >_>  How does one get the dimensions of a window? I'm trying to centre a
  424. >_>window before bringing it up.
  425. >
  426. >_>  Do I use portRect? Someone mentioned that I should use visRgn instead.
  427. >_>Is there a FAQ somewhere that I could look through?
  428. >
  429. >thePort->portRect gives you the size of the window's content area. If theu
  430. >window almost fills the screen, this can put the titlebar under the menubar.
  431. >Better you should use (**thePort->visRgn).rgnBBox (good idea to copy it into a 
  432. >temporary rect, in case the stuff you are using moves memory, since the visRgn
  433. >is a handle.)  The visRgn is in window local coordinates, so for a normal,
  434. >20 pixel high title bar, the top will be at -20.
  435.  
  436. Um, I think you want to look at the boundary box of the structure region,
  437. not the visRgn.  The titlebar area is not part of the grafPort of the window
  438. itself.
  439.  
  440. - -- 
  441. John Cavallino                  |  EMail: jcav@midway.uchicago.edu
  442. University of Chicago Hospitals |         John_Cavallino@uchfm.bsd.uchicago.edu
  443. Office of Facilities Management | USMail: 5841 S. Maryland Ave, MC 0953
  444. B0 f++ c+ g+ k s++ e+ h- pv     |         Chicago, IL  60637
  445.  
  446. ---------------------------
  447.  
  448. From: ccmlh@buitc.bu.edu (Mark Hayes)
  449. Subject: How to play MIDI resources?
  450. Date: 16 Jul 92 04:41:37 GMT
  451. Organization: Boston University, Boston, MA, USA
  452.  
  453. I was just poking around with ResEdit inside the game "Prince of Persia" 
  454. (which features some very nice music), and noticed a set of resources 
  455. with type "MIDI". Much to my surprise, when I looked at the actual data, 
  456. the individual resources turned out to be in standard MIDI file format! 
  457. And indeed, when I copied one out and saved it in a file, I was able to 
  458. import it into the MIDI application TRAX, and there was my Yamaha synth, 
  459. playing the theme from "Prince of Persia"!
  460.  
  461. My question is, how does the game play those MIDI resources? Is there 
  462. direct support in the system for this, or would the developers have had 
  463. to do a lot of MIDI support coding themselves? I couldn't find any help 
  464. on this in Inside Macintosh, though there were a few cryptic references 
  465. to MIDI; volume VI, in fact, says not a word about MIDI. Help, anyone? 
  466. If there is direct system support for playing MIDI files, I would love 
  467. to take a shot at coding what might be a fairly simple application to 
  468. play MIDI files directly through the Mac sound hardware. As far as I 
  469. know, there are no applications, and certainly no shareware applications,
  470. that currently do this.
  471.  
  472. Thanks to anyone for any help they can offer.
  473.  
  474. +++++++++++++++++++++++++++
  475.  
  476. From: zobkiw@world.std.com (Joe Zobkiw)
  477. Date: 16 Jul 92 16:56:05 GMT
  478. Organization: The World Public Access UNIX, Brookline, MA
  479.  
  480. Playing MIDI resources using the Sound Manager is something that you have
  481. to roll yourself. There is no direct support for this in the Toolbox. Not yet
  482. anyway ;)
  483.  
  484. There is a program available that exhibits this technology called MIDI CD. It
  485. is one of the best implementations I have seen (and one of the _only_)
  486.  
  487.  
  488. - -- 
  489. - -------------------------------------------------------------
  490. joe zobkiw         zobkiw@world.std.com        aol: aflzobkiw
  491.  
  492. ---------------------------
  493.  
  494. From: perm@csd.uu.se (Per Mildner)
  495. Subject: What is LDIVT (referenced in an MPW .o/.lib file?)
  496. Organization: Computing Science Dept.,Uppsala University, Sweden
  497. Date: Thu, 16 Jul 1992 10:38:55 GMT
  498.  
  499.  
  500. I'm trying to convert some MPW .o and .lib files for use with Think C
  501. (5.02). I get a link error for a routine LDIVT. When I add one of my
  502. own it gets called (surprise :-) and I have little idea what it should
  503. do. I know about ldiv and the ldiv_t type but that is probably not the
  504. same thing. I have looked in the MPW C manuals but cannot find it.
  505. Any help appreciated,
  506. - --
  507. Per Mildner            perm@CSD.UU.SE
  508. Computing Science Dept.        tel: +46 18181049
  509. Uppsala University, Sweden    fax: +46 18521270
  510.  
  511. +++++++++++++++++++++++++++
  512.  
  513. From: perm@csd.uu.se (Per Mildner)
  514. Date: 16 Jul 92 15:22:18 GMT
  515. Organization: Computing Science Dept.,Uppsala University, Sweden
  516.  
  517. In article <PERM.92Jul16113855@meryl.csd.uu.se> perm@csd.uu.se (Per Mildner) writes:
  518.  
  519.    I'm trying to convert some MPW .o and .lib files for use with Think C
  520.    (5.02). I get a link error for a routine LDIVT. ...
  521.    --
  522.  
  523. After a little mucking around I found this to be the long div
  524. instruction missing in processors less than 68020. (Also confirmed by
  525. a bug note for MPW C 3.2)
  526.  
  527. long LDIVT(void)
  528. { register long x;
  529.   register long y;
  530.  
  531.   asm {
  532.     move.l d0, x
  533.     move.l d1, y
  534.   };
  535.   return x/y;
  536. }
  537.  
  538. seems to do the trick. Somebodys code generator is bogus as y always
  539. was 8 in the libs... 
  540. If somebody's interested, this trick makes the expensive Oracle libs
  541. work with the Think C debugger...
  542. Happy hacking,
  543. - --
  544. Per Mildner            perm@CSD.UU.SE
  545. Computing Science Dept.        tel: +46 18181049
  546. Uppsala University, Sweden    fax: +46 18521270
  547.  
  548. ---------------------------
  549.  
  550. From: rrwood@uuisis.isis.org (Roy Wood)
  551. Subject: texedit records >32K (SUMMARY)
  552. Organization: International Shared Information Service (Ottawa)
  553. Date: Sat, 11 Jul 92 17:59:15 GMT
  554.  
  555. Thanks to everyone who responded to my question about whether there is a
  556. publicly available hack to replace TextEdit and correctly work with records
  557. larger than 32K.  Basically, there's a TCL package available from
  558. ftp.brown.edu, or a commercial package.  Here's the info:
  559.  
  560. From: zobkiw@world.std.com (Joe Zobkiw)
  561.  
  562. Check out ftp.brown.edu in the pub/tcl directory. There is a file by
  563. Chris Wysocki called (I think) CPEdit.c which is a THINK C TCL class
  564. that implements a >32K text editing engine.
  565.  
  566. (Vince Vann mentioned this package, too) 
  567.  
  568.  
  569. From: siegel@world.std.com (Rich Siegel)
  570. Subject: Re: textedit files >32K ?
  571.  
  572. Thanks for your interest in the Programmer's Editor Package (PE Package).
  573. If you wish to order, you should send payment and a request to me
  574. directly:
  575.  
  576. Rich Siegel
  577. 6 Village Way #23
  578. Natick, MA 01760
  579.  
  580. Cashier's check or bank draft is preferred. US funds are required. Orders
  581. paid with personal check will be held until the check clears. Presently,
  582. the time to fill an order is two to three weeks.
  583.  
  584. Here is pricing info. If you have specific technical questions or pricing
  585. needs, please let me know.
  586.  
  587. - ----
  588.  
  589. Pricing is as follows:
  590.  
  591.     -   single-user upgrade for users of the Symantec CAPPS package       $25
  592.             (requires original labeled floppy or other conclusive
  593.                 proof or purchase)
  594.                 
  595.     -   single-user new copy price (includes printed documentation)       $75
  596.     
  597.     
  598.     Licenses are available to use PEP for other than individual use.
  599.     Add the price to the single-user upgrade or single-user new copy
  600.     price, whichever is appropriate.
  601.     
  602.     -   product license for producers of freeware programs                $1
  603.         (for software authors who will release free programs
  604.             which use any part of the PEP package)
  605.             
  606.     -   product license for producers of shareware programs               $50
  607.         (for software authors who will release shareware programs
  608.             which use any part of the PEP package)
  609.             
  610.     -   product license for commercial or in-house use                    $100
  611.         (for software authors who will release programs for
  612.         commercial sale or corporate in-house use)
  613.  
  614.  
  615.  
  616. Again, thanks to all who replied.
  617.  
  618. - -Roy
  619.  
  620. ---------------------------
  621.  
  622. From: mxmora@unix.sri.com (Matthew Xavier Mora)
  623. Subject: Has anybody got disk dragging to work?
  624. Date: 14 Jul 92 01:37:59 GMT
  625. Organization: SRI International
  626.  
  627. In article <62042@cup.portal.com>, MacUserLabs@cup.portal.com (Stephan -
  628. Somogyi) wrote:
  629. > mxmora@unix.sri.com (Matthew Xavier Mora) writes:
  630. > >I'm working on a system seven only app and I can't get disk "drag and drop"
  631. > >to work. I did everyting IM vol 6 said to do but the finder will not hilight
  632. > >my app when I drag a disk icon over it.
  633. > Works swimmingly for my app. I have a BNDL/FREF with 'disk' as the doc type
  634. > and no icon for that type.
  635. > Could you expound on what you've tried, to provide some context? With more
  636. > information we might be able to narrow this down.
  637. > ________________________________________________________________________
  638. > Stephan Somogyi            peace, happiness, pancakes            MacUser
  639.  
  640. Sure,
  641.  
  642. I created a bndl resource with a file type of 'APPL','trak', and 'disk'.
  643. The size resource says that I'm apple event aware. I don't have a '****'
  644. file type because I don't deal with all files. Just certain disks, mainly
  645. cd audio disks. In my testing I'm trying to drag any kind of disk but none
  646. highlight my app and launch it. I rebuilt my desktop but to no avail. My
  647. beta testers say that it doesn't work on their macs either (assuming that
  648. my desktop might be littered with multiple versions of my program.) I would
  649. be glad to send the program to someone if they think they can tweek the
  650. bndl to get it to work. I guess my main question is do I need the 'fold'
  651. and '****' to make the 'disk' part work?
  652.  
  653. Matt
  654.  
  655. +++++++++++++++++++++++++++
  656.  
  657. From: leonardr@ccs.itd.umich.edu
  658. Organization: Campus Computing Sites, University of Michigan-Ann Arbor
  659. Date: Tue, 14 Jul 92 06:16:16 GMT
  660.  
  661. In article <mxmora-130792183032@css-mac1.sri.com> mxmora@unix.sri.com (Matthew Xavier Mora) writes:
  662. >In article <62042@cup.portal.com>, MacUserLabs@cup.portal.com (Stephan -
  663. >Somogyi) wrote:
  664. >> 
  665. >> mxmora@unix.sri.com (Matthew Xavier Mora) writes:
  666. >> 
  667. >> >I'm working on a system seven only app and I can't get disk "drag and drop"
  668. >> >to work. I did everyting IM vol 6 said to do but the finder will not hilight
  669. >> >my app when I drag a disk icon over it.
  670. >> 
  671. >> Works swimmingly for my app. I have a BNDL/FREF with 'disk' as the doc type
  672. >> and no icon for that type.
  673. >> 
  674. >I created a bndl resource with a file type of 'APPL','trak', and 'disk'.
  675. >The size resource says that I'm apple event aware. I don't have a '****'
  676. >file type because I don't deal with all files. Just certain disks, mainly
  677. >cd audio disks. 
  678. >I guess my main question is do I need the 'fold' and '****' to make the 'disk'
  679. >part work?
  680. >
  681.     For reasons that no one has ever explaned to me (other than a bug
  682. in the Finder ;), you MUST have '****' to use either fold or disk - you
  683. don't have to have all three.
  684.  
  685. - -- 
  686. - -----------------------------------------------------------------------
  687. Leonard Rosenthol          Internet: leonardr@ccs.itd.umich.edu
  688. Director of Advanced Technology   AppleLink: MACgician
  689. Aladdin Systems, inc.          GEnie:     MACgician
  690.  
  691. +++++++++++++++++++++++++++
  692.  
  693. From: fprefect@engin.umich.edu (Matt Slot)
  694. Date: 14 Jul 92 13:49:53 GMT
  695. Organization: University of Michigan, CAEN Mac-Systems
  696.  
  697.  
  698. I had similar problems getting Appleshare File Servers to drag-n-drop. My
  699. FREF's now include
  700.    APPL, PREF, disk, & fold. I don't use the wildcard, and my drop seems
  701. to work. I was told
  702.    that the Finder treats AShare File Servers as folders for some strange
  703. reason, and that is
  704.    why I have to deal with the whole problem of distinguishing real
  705. folders from volumes.
  706. I don't know how well this applies to your problem, but perhaps you may
  707. investigate what the
  708.    Finder thinks it is when it send the ODOC event. Remember that
  709. something is treating the
  710.    CD as a mountable volume, and is probably mucking about with the
  711. volume queue to do it--
  712.    so perhaps Audio-CD's have a special file type.
  713.  
  714. fprefect@caen.engin.umich.edu
  715. Matt Slot, CAEN Mac-Support
  716.  
  717. +++++++++++++++++++++++++++
  718.  
  719. From: greggor@Apple.COM (Greg L. Anderson)
  720. Date: 15 Jul 92 00:25:31 GMT
  721. Organization: Apple Computer Inc., Cupertino, CA
  722.  
  723. In article <1992Jul14.061616.7910@terminator.cc.umich.edu> leonardr@ccs.itd.umich.edu writes:
  724. >>I guess my main question is do I need the 'fold' and '****' to make the 'disk'
  725. >>part work?
  726.  
  727. >    For reasons that no one has ever explaned to me (other than a bug
  728. >in the Finder ;), you MUST have '****' to use either fold or disk - you
  729. >don't have to have all three.
  730.  
  731. Nope, not true--I just built an App with 'fold' and 'disk', and it
  732. accepts both folders and disks.  It does not have '****' in the FREF.
  733.  
  734. The bad news is that you must have 'fold' in your FREF if you expect to
  735. receive drops from disks.  This is because the 7.0 Finder gets confused when
  736. it sees a disk, and thinks it's a folder and checks to see if your app will
  737. accept 'fold' instead of checking for 'disk'.  Any app with 'fold' in its
  738. FREF will accept drops from both folders and disks in System 7.0 and
  739. 7.0.1.  'disk' is never checked for in these versions of the Finder.
  740.  
  741. 7.1 fixes the bug, though, so you should have 'disk' in your FREF if you want
  742. to be able to receive drag-and-drop disks and not break with future Finders.
  743.  
  744. - -- 
  745. =====================   ===========================   =====================
  746. Greg Anderson           Apple Computer, Inc.            O    Ponnuki    O
  747. Macintosh Bodhisattva   Macintosh System Software      O O  is  ideal  O O
  748. greggor@apple.com       Finder Team                     O     shape     O
  749. =====================   ===========================   =====================
  750.  
  751. +++++++++++++++++++++++++++
  752.  
  753. From: stanger@otago.ac.nz (Nigel Stanger)
  754. Date: 15 Jul 92 15:26:37 +1300
  755. Organization: University of Otago, Dunedin, New Zealand
  756.  
  757. fprefect@engin.umich.edu (Matt Slot) writes:
  758. >
  759. > I had similar problems getting Appleshare File Servers to drag-n-drop. My
  760. > FREF's now include
  761. >    APPL, PREF, disk, & fold. I don't use the wildcard, and my drop seems
  762. > to work. I was told
  763. [...]
  764.  
  765. You'll like this. One of my apps handles disk dropping, but it's
  766. BNDL only contains '****' and 'fold'. It doesn't have 'disk' at
  767. all! Works great. And as far as the app is concerned, it's just
  768. another FSSpec. You have to test for parID = fsRtParID to tell
  769. whether it's a disk or not.
  770.  
  771. - ----------------------------------------------------------------------
  772. Nigel Stanger,                  Internet: stanger@otago.ac.nz
  773. University of Otago,            Phone: +64 3 479-8179
  774. Dunedin, NEW ZEALAND.           Fax:   +64 3 479-8311
  775. String Quartet: see RUBBER BAND.
  776.  
  777. +++++++++++++++++++++++++++
  778.  
  779. From: Andreas Wuertz <wuertz@systech.tik.ethz.ch>
  780. Organization: Swiss Federal Institute of Technology, TIK
  781. Date: Wed, 15 Jul 1992 07:15:27 GMT
  782.  
  783. In article <mxmora-130792104617@css-mac1.sri.com> Matthew Xavier Mora,
  784. mxmora@unix.sri.com writes:
  785. >I'm working on a system seven only app and I can't get disk "drag and
  786. >drop" to work. I did everyting IM vol 6 said to do but the finder
  787. >will not hilight my app when I drag a disk icon over it. Beta testers
  788. >tell me it won't work on their machines either.  ( I thought it might be 
  789. >a desktop database problem) So how do you get disk dropping to work?
  790. Stupid Question: Did you set the app's bundle bit?
  791.  
  792. Andy from TIK
  793.  
  794. =======================================================
  795. The earliest time for a program to be bug-free is,
  796. when it's out of date. The latest time for a programmer
  797. to retire is, when he writes such a program.
  798. =======================================================
  799.  
  800. +++++++++++++++++++++++++++
  801.  
  802. From: Andreas Wuertz <wuertz@systech.tik.ethz.ch>
  803. Organization: Swiss Federal Institute of Technology, TIK
  804. Date: Wed, 15 Jul 1992 07:16:19 GMT
  805.  
  806. In article <mxmora-130792104617@css-mac1.sri.com> Matthew Xavier Mora,
  807. mxmora@unix.sri.com writes:
  808. >I'm working on a system seven only app and I can't get disk "drag and
  809. >drop" to work. I did everyting IM vol 6 said to do but the finder
  810. >will not hilight my app when I drag a disk icon over it. Beta testers
  811. >tell me it won't work on their machines either.  ( I thought it might be 
  812. >a desktop database problem) So how do you get disk dropping to work?
  813. Stupid Question: Did you set the app's bundle bit?
  814.  
  815. Andy from TIK
  816.  
  817. =======================================================
  818. The earliest time for a program to be bug-free is,
  819. when it's out of date. The latest time for a programmer
  820. to retire is, when he writes such a program.
  821. =======================================================
  822.  
  823. ---------------------------
  824.  
  825. From: wong_a@summer.chem.su.oz.au
  826. Subject: ioCompletion and AppleTalk
  827. Organization: School of Chemistry, University of Sydney
  828. Date: Wed, 15 Jul 1992 01:14:02 GMT
  829.  
  830.  
  831. What parameters are passed back to an ioCompletion routine in AppleTalk?
  832. Say for example in a ATPParamBlock, where can I hide my oldA5 pointer? 
  833. Any examples of ioCompletion routines would be appreciated....
  834.  
  835. Thanks Adrian.
  836.  
  837. - -----------------------------------------------------------------------------
  838. Adrian Wong, Dept.of Theoretical Chemistry     wong_a@summer.chem.su.oz.au
  839. University of Sydney NSW 2006 Australia        061-2-692 4137
  840.  
  841.  
  842. +++++++++++++++++++++++++++
  843.  
  844. From: zobkiw@world.std.com (Joe Zobkiw)
  845. Date: 14 Jul 92 17:00:12 GMT
  846. Organization: The World Public Access UNIX, Brookline, MA
  847.  
  848. << What parameters are passed back to an ioCompletion routine in AppleTalk?
  849. Say for example in a ATPParamBlock, where can I hide my oldA5 pointer?  >>
  850.  
  851. Most parameter blocks contain a refcon that you can use for your own data.
  852. You can also do something like in many cases:
  853.  
  854. typedef struct {
  855.     ATPParamBlock    atpBlock;
  856.     MyXtraInfo    xtraInfo;
  857. } CustomATPBlock;
  858.  
  859. In theory, you can pass a CustomATPBlock to any routine that wants a
  860. ATPParamBlock and it _might_ work for you. This is mostly seen when
  861. people want to have data associated with a WinowPtr. You might see
  862.  
  863. typedef struct {
  864.     WindowPtr    w;
  865.     MyXtraInfo    xtraInfo;
  866. }
  867.  
  868. Hope this helps.
  869.  
  870.  
  871. - -- 
  872. - -------------------------------------------------------------
  873. joe zobkiw         zobkiw@world.std.com        aol: aflzobkiw
  874.  
  875. +++++++++++++++++++++++++++
  876.  
  877. From: jcav@quads.uchicago.edu (JohnC)
  878. Date: 14 Jul 92 17:27:43 GMT
  879. Organization: The Royal Society for Putting Things on Top of Other Things
  880.  
  881. In article <BrE1wE.2J6@world.std.com> zobkiw@world.std.com (Joe Zobkiw) writes:
  882. ><< What parameters are passed back to an ioCompletion routine in AppleTalk?
  883. >Say for example in a ATPParamBlock, where can I hide my oldA5 pointer?  >>
  884. >
  885. >Most parameter blocks contain a refcon that you can use for your own data.
  886. >You can also do something like in many cases:
  887. >
  888. >typedef struct {
  889. >    ATPParamBlock    atpBlock;
  890. >    MyXtraInfo    xtraInfo;
  891. >} CustomATPBlock;
  892. >
  893. >In theory, you can pass a CustomATPBlock to any routine that wants a
  894. >ATPParamBlock and it _might_ work for you. This is mostly seen when
  895.                       ^^^^^^^
  896. >people want to have data associated with a WindowPtr.
  897.  
  898. I see no need to qualify your statement with "might".  There's no reason that
  899. such a tactic would fail in any case involving a fully-documented OS
  900. structure.  People do it all the time.
  901.  
  902. - -- 
  903. John Cavallino                  |  EMail: jcav@midway.uchicago.edu
  904. University of Chicago Hospitals |         John_Cavallino@uchfm.bsd.uchicago.edu
  905. Office of Facilities Management | USMail: 5841 S. Maryland Ave, MC 0953
  906. B0 f++ c+ g+ k s++ e+ h- pv     |         Chicago, IL  60637
  907.  
  908. +++++++++++++++++++++++++++
  909.  
  910. From: peirce@outpost.SF-Bay.org (Michael Peirce)
  911. Date: 14 Jul 92 17:57:53 GMT
  912. Organization: Peirce Software
  913.  
  914.  
  915. In article <1992Jul14.201402.1@summer.chem.su.oz.au> (comp.sys.mac.programmer), wong_a@summer.chem.su.oz.au writes:
  916. > What parameters are passed back to an ioCompletion routine in AppleTalk?
  917. > Say for example in a ATPParamBlock, where can I hide my oldA5 pointer? 
  918. > Any examples of ioCompletion routines would be appreciated....
  919.  
  920. I describe a useful technique in Programming With AppleTalk.  It works
  921. like this:
  922.  
  923. Declare an "extended" parameter block something like this:
  924.  
  925.     myATPParamBlock = RECORD
  926.         dataPtr        : LongInt;
  927.         realATPPB    : ATPParamBlock;
  928.     END; {myATPParamBlock}
  929.  
  930. This puts the address of your data block (containing any context you
  931. need at interrupt time) four bytes in front of the parameter block.
  932. This means that it can be easily access off of register A0 at completion
  933. time (A0 contains a pointer to your parameter block).  I prefer to
  934. put the extra data pointer in front of the block because then the
  935. same code works with a variety of parameter block sizes.
  936.  
  937. Next I issue an AppleTalk call something like the following:
  938.  
  939.     IF PGetRequest(@inATPPB.realATPPB,kASYNC) <> noErr THEN ...
  940.  
  941. I set my ioCompletion routine to point to some assembly language glue
  942. that looks like the following:
  943.  
  944. ;---------------------------------------------------------
  945. ;
  946. ;    Example Resident Code Macro Glue
  947. ;
  948. ;    The idea here is that the completion routines need 
  949. ;    to have some context (the data block where we store
  950. ;    all our variables) when they run.  So what we do 
  951. ;    here in front of the io block, and push it onto the 
  952. ;    stack.  This allows the Pascal code to take it in
  953. ;    as a parameter and then do a nice big WITH.  The 
  954. ;    effect is that all data is stored off A4 (setup by
  955. ;    the with) instead of A5 (bad carma is used from 
  956. ;    within a completion routine.  
  957. ;
  958. ;    Oh yes, we also do the usual register store/reload
  959. ;    stuff here so we don't step on interrupted code.
  960. ;
  961.     BLANKS        ON
  962.     INCLUDE        '::AIncludes:SysEqu.a'
  963.     IMPORT        INCOMING
  964. ;---------------------------------------------------------
  965. XINCOMING PROC        EXPORT    ; Glue for INCOMING procedure
  966.  
  967.     MOVEM.L        D3-D7/A2-A6,-(A7) ; save them registers
  968.     MOVE.L        -4(A0),D0          ; get our block pointer
  969.     MOVE.L        D0,-(A7)          ; pass it as a parameter
  970.     JSR            INCOMING          ; call Pascal routine
  971.     MOVEM.L        (A7)+,A2-A6/D3-D7 ; restore the registers
  972.     RTS
  973. ;---------------------------------------------------------
  974.     END
  975.  
  976. This calls my Pascal routine that does the real work.  It looks something
  977. like this:
  978.  
  979.  
  980. (********************************************************)
  981. PROCEDURE Incoming( dataBlock : DataBlockPtr);
  982. BEGIN {Incoming}
  983.     WITH dataBlock^ DO BEGIN
  984.  
  985.     etc......
  986.  
  987. END;
  988.  
  989.  
  990. Of course you can do something very similar with C rather than Pascal
  991. if you'd rather.
  992.  
  993. This is all written in MPW Pascal and Assembler and you can get a
  994. more thorough explaination in Programming with AppleTalk from Addison-Wesley
  995. ISBN: 0-201-57780-1 57780
  996.  
  997. - --  Michael Peirce      --   peirce@outpost.SF-Bay.org
  998. - --  Peirce Software     --   Suite 301, 719 Hibiscus Place
  999. - --                      --   San Jose, California USA 95117
  1000. - --  Makers of...        --   voice: (408) 244-6554 fax: (408) 244-6882
  1001. - --            SMOOTHIE  --   AppleLink: peirce & America Online: AFC Peirce
  1002.  
  1003. ---------------------------
  1004.  
  1005. From: wdh@well.sf.ca.us (Bill Hofmann)
  1006. Subject: Catching phys ATalk connection
  1007. Organization: Whole Earth 'Lectronic Link
  1008. Date: Tue, 14 Jul 1992 16:27:10 GMT
  1009.  
  1010. OK, here's a question for y'all:  I want to notice when a user plugs in their
  1011. appletalk cable, in particular when they're connected to a zone.  There
  1012. doesn't appear to be an AppleTalk transition event for this happening.  The
  1013. only thing that comes to my mind is every so often polling for GetMyZone.
  1014. If you're not connected, you'll fail immediately, and if you're connected,
  1015. you'll get a zone back quick, except for the first transition in either
  1016. direction, which seems to take a couple of seconds.  Is this the only way?
  1017.  
  1018. - -Bill Hofmann
  1019.  
  1020. +++++++++++++++++++++++++++
  1021.  
  1022. From: jcav@quads.uchicago.edu (JohnC)
  1023. Date: 14 Jul 92 17:38:47 GMT
  1024. Organization: The Royal Society for Putting Things on Top of Other Things
  1025.  
  1026. In article <wdh.711131230@well.sf.ca.us> wdh@well.sf.ca.us (Bill Hofmann) writes:
  1027. >OK, here's a question for y'all:  I want to notice when a user plugs in their
  1028. >appletalk cable.
  1029.  
  1030. Yeep!  I don't think that's really safe to do without restarting, in order
  1031. to obtain an unused node address, etc.  I believe that the Network control
  1032. panel does a "soft reboot" of Appletalk when you change connections, but I
  1033. don't think there's any other way.
  1034.  
  1035. - -- 
  1036. John Cavallino                  |  EMail: jcav@midway.uchicago.edu
  1037. University of Chicago Hospitals |         John_Cavallino@uchfm.bsd.uchicago.edu
  1038. Office of Facilities Management | USMail: 5841 S. Maryland Ave, MC 0953
  1039. B0 f++ c+ g+ k s++ e+ h- pv     |         Chicago, IL  60637
  1040.  
  1041. ---------------------------
  1042.  
  1043. End of C.S.M.P. Digest
  1044. **********************
  1045.